package com.zlll.winner.service.activity;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.zlll.winner.business.model.activity.ActivityApplyExternal;
import com.zlll.winner.mapper.activity.ActivityApplyExternalMapper;
import com.zlll.winner.business.service.activity.IActivityApplyExternalService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.apache.dubbo.config.annotation.Service;

import java.util.List;

/**
 * <p>
 * 活动申请拓展字段表 服务实现类
 * </p>
 *
 * @author qsx
 * @since 2019-09-16
 */
@Service
public class ActivityApplyExternalServiceImpl extends ServiceImpl<ActivityApplyExternalMapper, ActivityApplyExternal> implements IActivityApplyExternalService {


    @Override
    public List<ActivityApplyExternal> getExternalByActivityId(Long activityId) {
        LambdaQueryWrapper<ActivityApplyExternal> externalLambdaQueryWrapper = Wrappers.lambdaQuery();
        externalLambdaQueryWrapper.eq(ActivityApplyExternal::getActivityId,activityId);
        externalLambdaQueryWrapper.eq(ActivityApplyExternal::getIsDel,0);
        return list(externalLambdaQueryWrapper);
    }
}
